package edu.ustb.efws.meter.domain;

import com.fasterxml.jackson.annotation.JsonIgnore;

import java.util.Date;
import java.util.StringJoiner;

/**
 * 测量值
 *
 * @author TS Group
 */
public class Meter {

    /**
     * 编号
     */
    @JsonIgnore
    private Long id;

    /**
     * 测量点编号
     */
    private Integer positionId;

    /**
     * 月(yyyyMM)
     */
    private Integer month;

    /**
     * 天
     */
    private Integer day;

    /**
     * 小时
     */
    private Integer hour;

    /**
     * 分
     */
    private Integer minute;

    /**
     * 开始分数
     */
    private Float startScore;

    /**
     * 结束分数
     */
    private Float endScore;

    /**
     * 最大分数
     */
    private Float maxScore;

    /**
     * 最小分数
     */
    private Float minScore;

    /**
     * 总分数
     */
    private Float totalScore;

    /**
     * 总次数
     */
    private Integer count;

    /**
     * 平均分数
     */
    private Float score;

    /**
     * 危险级别
     */
    private String grade;

    /**
     * 创建时间
     */
    private Date createTime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Integer getPositionId() {
        return positionId;
    }

    public void setPositionId(Integer positionId) {
        this.positionId = positionId;
    }

    public Integer getMonth() {
        return month;
    }

    public void setMonth(Integer month) {
        this.month = month;
    }

    public Integer getDay() {
        return day;
    }

    public void setDay(Integer day) {
        this.day = day;
    }

    public Integer getHour() {
        return hour;
    }

    public void setHour(Integer hour) {
        this.hour = hour;
    }

    public Integer getMinute() {
        return minute;
    }

    public void setMinute(Integer minute) {
        this.minute = minute;
    }

    public Float getStartScore() {
        return startScore;
    }

    public void setStartScore(Float startScore) {
        this.startScore = startScore;
    }

    public Float getEndScore() {
        return endScore;
    }

    public void setEndScore(Float endScore) {
        this.endScore = endScore;
    }

    public Float getMaxScore() {
        return maxScore;
    }

    public void setMaxScore(Float maxScore) {
        this.maxScore = maxScore;
    }

    public Float getMinScore() {
        return minScore;
    }

    public void setMinScore(Float minScore) {
        this.minScore = minScore;
    }

    public Float getTotalScore() {
        return totalScore;
    }

    public void setTotalScore(Float totalScore) {
        this.totalScore = totalScore;
    }

    public Integer getCount() {
        return count;
    }

    public void setCount(Integer count) {
        this.count = count;
    }

    public Float getScore() {
        return score;
    }

    public void setScore(Float score) {
        this.score = score;
    }

    public String getGrade() {
        return grade;
    }

    public void setGrade(String grade) {
        this.grade = grade;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Override
    public String toString() {
        return new StringJoiner(", ", Meter.class.getSimpleName() + "[", "]")
                .add("id=" + id)
                .add("positionId=" + positionId)
                .add("month=" + month)
                .add("day=" + day)
                .add("hour=" + hour)
                .add("minute=" + minute)
                .add("startScore=" + startScore)
                .add("endScore=" + endScore)
                .add("maxScore=" + maxScore)
                .add("minScore=" + minScore)
                .add("totalScore=" + totalScore)
                .add("count=" + count)
                .add("score=" + score)
                .add("grade='" + grade + "'")
                .add("createTime=" + createTime)
                .toString();
    }
}
